package com.omicrondev.flightops;

/**
 * Created by gdean on 7/30/13.
 */
public class CGStation implements Comparable<CGStation> {
    public String mName;
    public double mArm = 0;
    public int mMinWeight = 0;
    public int mMaxWeight = 0;
    public boolean mIsFuel = false;
    public boolean mIsHidden = false;

    public int mValue = 0;

    public CGStation(String name, double arm, int minWeight, int maxWeight, boolean isFuel, boolean isHidden) {
        mName = name;
        mArm = arm;
        mMinWeight = minWeight;
        mMaxWeight = maxWeight;
        mIsFuel = isFuel;
        mIsHidden = isHidden;
    }

    @Override
    public String toString() {
        return mName;
    }

    public int compareTo(CGStation other) {
        if (mArm < other.mArm) {
            return -1;
        }
        else if (mArm == other.mArm) {
            return mName.compareTo(other.mName);
        }
        else {
            return 1;
        }
    }
}
